package com.zph.service;

import java.io.IOException;
import java.io.Reader;
import java.util.TreeMap;

import org.apache.ibatis.io.Resources;
import org.apache.ibatis.session.SqlSession;
import org.apache.ibatis.session.SqlSessionFactory;
import org.apache.ibatis.session.SqlSessionFactoryBuilder;

import com.zph.dao.IDatabaseDao;
import com.zph.dao.ResumeToTxt;
import com.zph.entity.CVObject;

public class test {
	public static void main(String[] args) {
		/// *
		String resource = "MyBatis-Configuration.xml";
		Reader reader = null;
		try {
			reader = Resources.getResourceAsReader(resource);
		} catch (IOException e) {
			e.printStackTrace();
		}
		SqlSessionFactoryBuilder builder = new SqlSessionFactoryBuilder();
		SqlSessionFactory factory = builder.build(reader);
		SqlSession session = factory.openSession();
		IDatabaseDao dao = session.getMapper(IDatabaseDao.class);
		CVObject map = new CVObject();
		map = null;
		// System.out.println(map);
		// ParseList.parseBehind(10,"C:\\Users\\Shu\\Desktop\\eclipse-jee-mars-1-win32-x86_64\\eclipse\\寻访记录\\Chinameditech
		// - DSM - Amanda.xls",dao);
		// ResumeToTxt.parseWord(0, 0, 0,
		// "C:\\Users\\Shu\\Desktop\\公司文件文档\\文档\\resume\\resume_刘祥涛3.pdf", map,
		// dao);
		// ResumeToTxt.parseWord(0, 0, 0,
		// "C:\\Users\\Shu\\Desktop\\1\\智联招聘_刘珊珊_UI设计师_中文_20150806_60271311.doc",
		// map, dao);
		
		
		ResumeToTxt.parseWord(0, 0, 0, "C:/cv/Java_zzf9.doc", map, dao);
//		ResumeToTxt.parseWord(0, 0, 0, "C:/cv/高盘龙 .doc", map, dao);
		
		
		 
		// ResumeToTxt.parsePdf(0, 0, 0, "C:/cv/张飞_吉林大学.pdf", map, dao);
		// ImportList.parseBehind(0, 0,
		// 0,"C:\\Users\\Shu\\Desktop\\联系人.xlsx",dao);Shanxi Jincheng Anthracite
		// Coal Mining Group,15/计算机硬件维护工程师,14/
		
		//session.commit();

		// */
		 
	}
}
